home *** CD-ROM | disk | FTP | other *** search
/ Aminet 28 / Aminet 28 (1998)(GTI - Schatztruhe)[!][Dec 1998].iso / Aminet / game / shoot / athrust.lha / AmigaThrust / src / things.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-09-05  |  2.2 KB  |  99 lines

  1.  
  2. /* Written by Peter Ekberg, peda@lysator.liu.se */
  3.  
  4. #ifndef THINGS_H
  5. #define THINGS_H
  6.  
  7. #include "thrust_t.h"
  8.  
  9. struct bulletdef {
  10.   int life,x,y,vx,vy,dir,owner;
  11. };
  12. typedef struct bulletdef bullet;
  13.  
  14. struct fragmentdef {
  15.   int life,x,y,vx,vy;
  16. };
  17. typedef struct fragmentdef fragment;
  18.  
  19. struct thingdef    {
  20.   int alive,px,py,x,y,type,score;
  21.   void *data;
  22. };
  23. typedef struct thingdef thing;
  24. extern word nrthings;
  25.  
  26. struct sliderdef {
  27.   int type,x1,y1,x2,y2,dir,active,stage,count,match;
  28.   struct sliderdef *next;
  29. };
  30. typedef struct sliderdef slider;
  31. extern word nrsliders;
  32.  
  33. struct buttondatadef {
  34.   int major;
  35.   int tag;
  36.   slider *sliders;
  37. };
  38. typedef struct buttondatadef buttondata;
  39.  
  40. struct restartpointdef {
  41.   word x, y;
  42. };
  43. typedef struct restartpointdef restartpoint;
  44. extern word nrrestartpoints;
  45.  
  46. struct barrierdef {
  47.   word x, y;
  48.   restartpoint *restart;
  49. };
  50. typedef struct barrierdef barrier;
  51. extern word nrbarriers;
  52.  
  53.  
  54. #define maxbullets (64)
  55. extern bullet bullets[maxbullets];
  56. #define maxfragments (512)
  57. extern fragment fragments[maxfragments];
  58. #define maxthings (32)
  59. extern thing things[maxthings];
  60. #define maxsliders (32)
  61. extern slider sliders[maxsliders];
  62. #define maxbarriers (512)
  63. extern barrier barriers[maxbarriers];
  64. #define maxrestartpoints (16)
  65. extern restartpoint restartpoints[maxrestartpoints];
  66.  
  67. extern word powerplant;
  68. extern word ppx, ppy, ppcount;    /* Power Plant variables */
  69. extern word ppblip;
  70.  
  71. #ifdef __STDC__
  72. void newslider(int x, int y, int type);
  73. int majorbutton(int button);
  74. void newthing(int x, int y, int px, int py, int type, void *data);
  75. void animatesliders(void);
  76. void startupsliders(int button);
  77. restartpoint *atbarrier(word bx, word by);
  78. void deletething(thing *tp);
  79. void newbullet(word x, word y, int vx, int vy, word dir, int owner);
  80. void movebullets(void);
  81. word crashtype(word type);
  82. int inloadcontact(int x, int y);
  83. int resonablefuel(int x, int y, int l);
  84. int closestfuel(int x, int y);
  85. int closestbutton(int x, int y);
  86. void hit(word x, word y, word crash, word owner);
  87. void bunkerfirebullet(thing *b);
  88. void bunkerfirebullets(void);
  89. int killdyingthings(void);
  90. void killallthings(void);
  91. void newfragment(word x, word y);
  92. void explodething(thing *thingptr);
  93. void explodeship(void);
  94. void movefragments(void);
  95. word livefragments(void);
  96. #endif
  97.  
  98. #endif /* THINGS_H */
  99.